package cn.wolfcode.luowowo.article.service;

import cn.wolfcode.luowowo.article.domain.StrategyDetail;
import cn.wolfcode.luowowo.article.domain.Travel;
import cn.wolfcode.luowowo.article.domain.TravelContent;
import cn.wolfcode.luowowo.common.query.QueryObject;
import cn.wolfcode.luowowo.common.util.AjaxResult;
import com.github.pagehelper.PageInfo;

import java.util.List;

public interface ITravelService {
    PageInfo query(QueryObject qo);

    Travel get(Long id);

    /**
     * 根据目的地id查询阅读量前三的游记
     * @param destId
     * @return
     */
    List<Travel>listVeiwnumTop3(Long destId);

    TravelContent  getContent(Long id);

    AjaxResult saveOrUpdate(Travel travel);

    List<Travel> list();

    List<Travel> listAll();

    void updateState(Travel travel);
    /**
     * 根据用户id查询游记和游记内容和父类名字
     * @param userId
     * @return
     */
    List<Travel> selectByUserId(Long userId);

    /**
     * 通过游记的id查询出作者的id
     * @param id
     * @return
     */
    Long selectByTravel(Long id);


    Travel selectById(Long travelId);
}
